{% extends "admin/admin.html" %}

{% block content %}
    <div class="box-body table-responsive no-padding">
    {% include 'admin/alert_info.html' %}
    <table class="table table-hover">
        <tbody>
        <tr>
            <th>编号</th>
            <th>角色名称</th>
            <th>添加时间</th>
            <th>操作事项</th>
        </tr>
        {% for role in page_roles.items %}
            <tr>
                <td>{{ role.id }}</td>
                <td>{{ role.name }}</td>
                <td>{{ role.add_time }}</td>
                <td>
                    <a class="label label-success" href="{{ url_for('admin.role_update', update_id=role.id) }}">编辑</a>
                    &nbsp;
                    <a class="label label-danger" href="{{ url_for('admin.role_delete', delete_id=role.id) }}">删除</a>
                </td>
            </tr>
        {% endfor %}
        </tbody>
    </table>
</div>
<div class="box-footer clearfix">
    {% import 'ui/admin_page.html' as pg %}
    {{ pg.page(page_roles, 'admin.role_list') }}
</div>

{% endblock %}
